using SCBK.Api.Model;
using Microsoft.EntityFrameworkCore;
namespace SCBK.Api.Db
{
    public class SCDB : DbContext
    {
        public SCDB() { }
        public SCDB(DbContextOptions options) : base(options) { }

        public DbSet<Admin> Admins { get; set; }
        public DbSet<Attribute_value> Attribute_value { get; set; }
        public DbSet<Attribute> Attribute { get; set; }
        public DbSet<Broadcast_map> Broadcast_map { get; set; }
        public DbSet<Comment> Comment { get; set; }
        public DbSet<Commodity_category> Commodity_category { get; set; }
        public DbSet<Details> Details { get; set; }
        public DbSet<MallMsg> MallMsg { get; set; }
        public DbSet<Merchandise> Merchandise { get; set; }
        public DbSet<Merchant> Merchant { get; set; }
        public DbSet<Order> Order { get; set; }
        public DbSet<Pay> Pay { get; set; }
        public DbSet<Praise> Praise { get; set; }
        public DbSet<Receiving_information> Receiving_information { get; set; }
        public DbSet<Shopping_Cart> Shopping_Cart { get; set; }
        public DbSet<Specifications> Specifications { get; set; }
        public DbSet<Supplier> Supplier { get; set; }
        public DbSet<User> User { get; set; }
        public DbSet<UserMsg> UserMsg { get; set; }
        protected override void OnModelCreating(ModelBuilder builder)
        {
            builder.Seed();
        }
        protected override void OnConfiguring(DbContextOptionsBuilder builder)
        {
            builder.UseSqlServer(@"server=LAPTOP-AS39K086\MSSQLSERVER1;database=SCDB;uid=HUANG;pwd=571193002");
        }

    }
}